package com.ibiaoke.system.controller;

import com.ibiaoke.common.response.Res;
import com.ibiaoke.system.service.AreaService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

/**
 * Created by huhaichao on 2017/6/25.
 */
@Controller
public class AreaController {
    @Autowired
    private AreaService areaService;

    @RequestMapping("/listProvince")
    @ResponseBody
    public Res listProvince(){
        return Res.create().addResponse("provinces",areaService.listProvince());
    }

}
